void normalizar_local_c (
	unsigned char *src,
	unsigned char *dst,
	int m,
	int n,
	int row_size
) {

	for(int i = 1; i < m - 1; i++)
	{
		for(int j = 1; j < n - 1; j++)
		{
			unsigned char min = 255;
			unsigned char max = 0;
			for(int i_local = -1; i_local < 2; i_local++)
			{
				for(int j_local = -1; j_local < 2; j_local++)
				{
					unsigned char tmp;
					tmp = src[(i + i_local) * row_size + (j + j_local)];

					if(tmp < min)
						min = tmp;

					if(tmp > max)
						max = tmp;
				}
			}

			unsigned char valor_actual;

			valor_actual = src[(i + 1) * row_size + (j + 1)];

			if(valor_actual == max)
			{
				dst[i * row_size + j] = 1 + min;
			}
			else
			{
				dst[i * row_size + j] = min;
			}
		}
	}
}
